<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <h1>扩展运算符-用于参数传递</h1>
    <script>
        // console.log(Math.max(1, 2, 3, 1999, 4, 100, 999));
        // console.log(Math.min(1, 2, 3, 1999, 4, 100, 999));
        var arr = [1, 2, 3, 1999, 4, 100, 999]
        console.log(Math.max(...arr));
        console.log(Math.min(...arr));
    </script>
</body>

</html>